or indicate URL below. - Help, Benchmarks.
TNANTIComp.Options:
[Clear]
Using the program text above ...

2013-02-12 14:47:02 (CET) cTI start

% cTI_lt 0.25 using 23.619 MLIPS SICStus 3.8.5 (x86-linux-glibc2.1): Mon Oct 30 16:34:14 CET 2000.
% cTI: Rt=216ms, Wt=221ms, GC=4ms. NTI: Rt=12ms, Wt=8ms at most 74 inferences for useful informations.
% using the norm [[_|A]=l(A),s(_)=s].

% NTI summary: 3 cases unresolved, 0 predicates have been ignored: []

app(A,B,C)terminates_if b(A);b(C).
    % optimal. loops found: [app([A|_],x,[A|_])]. NTI took    4ms,72i,72i
app2(A,B,C,D)terminates_if true.
app2len(A,B,C)terminates_if false.
    % 2 unresolved: [app2len(b,f,b),app2len(b,f,f)].
    % loops found: [app2len(s(_),x,_),app2len(s(_),x,y)]. NTI took    0ms,74i,74i
list_lensx(A,B)terminates_if b(A).
    % 1 unresolved: [list_lensx(f,b)].
    % loops found: [list_lensx([_|_],s(_))]. NTI took    4ms,72i,72i

% Comparison with termination analyzers
% A termination analyser of identical power would verify
% with the following 7 proofs the 4 inferred conditions:

app(f, f, b).
    % ==> termination proof established
app(b, f, f).
    % ==> termination proof established
app(f, b, f).
    % ==> no proof found
app2(f, f, f, f).
    % ==> termination proof established
app2len(b, b, b).
    % ==> no proof found
list_lensx(b, f).
    % ==> termination proof established
list_lensx(f, b).
    % ==> no proof found
2013-02-12 14:47:02 (CET) cTI finished

Tooltip: You can skip this comparison with termination analyzers by selecting "Comp. skipped" above

Tooltip: Editing larger programs in the textarea is cumbersome. Consider using cTI within Emacs or specifying an URL!

Analyzed program:

:- cti:norm_tmap([ [_|Xs] = l(Xs), s(_) = s ]).
% simulating the traditional list-length norm for this program:
% all function symbols other than the list constructor count as 0

app2(A,B,Bs,Cs) :-
	app([A,B], Bs, Cs).

app([], As, As).
app([E|Es], Fs, [E|Gs]) :-
 	app(Es, Fs, Gs).

list_lensx([], 0).
list_lensx([_|Xs], s(N)) :-
	list_lensx(Xs, N).

app2len(N, Bs,Cs) :-
	list_lensx(As, N),
	app(As, Bs, Cs).

Valid HTML 4.0cTI, Fred Mesnard (Université de La Réunion), Ulrich Neumerkel (Technische Universität Wien)